package com.yzd.learnjava.generics;

import com.yzd.learnjava.util.Print;

public class PlainGenericInHeritance {
	public static void main(String[] args) {
		Base base = new Base();
		Derived derived = new Derived();
		DerivedGS gs = new DerivedGS();
		
		gs.set(base);
		gs.set(derived);
	}
}
class GenericSetter<T>{
	void set(T arg) {
		Print.print("GenericSetter.set(Base)");
	}
}
class DerivedGS extends GenericSetter<Base>{
	void set(Derived derived) {
		Print.print("DerivedGS.set(Derived)");
	}
}
